<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Grid extends MX_Controller {

	function __construct()
	{
		parent::__construct();
	}
	
	function select($modelName)
	{
		$this->load->model($modelName, false);
		$model = new $modelName();
		$collection = array_keys($model->getCollection());
		$output = '';
		foreach ($collection as $id) {
			$output .= ',' . $id . ',';
		}
		echo $output;
	}
}
